<!DOCTYPE html>
<html lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<!-- <meta name="viewport" content="target-densitydpi=device-dpi,width=750,user-scalable=no" /> -->
	<meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=no" />
	<title>自定义</title>
	<meta http-equiv="cleartype" content="on">
	<meta name="apple-mobile-web-app-title" content="...">
	<meta name="apple-mobile-web-app-capable" content="yes">
	<meta name="format-detection" content="telephone=no">
	<meta http-equiv="x-rim-auto-match" content="none">
	<meta name="apple-touch-fullscreen" content="yes">
	<meta name="apple-mobile-web-app-status-bar-style" content="black">
	<!-- windows phone 点击无高光 -->
	<meta name="msapplication-tap-highlight" content="no">
	<link rel="stylesheet" type="text/css" href="/css/base.css" />
	<link rel="stylesheet" type="text/css" href="/js/mobile/lib/idangerous.swiper.css" />
	<script type="text/javascript" src="/js/mobile/lib/jquery-1.10.1.min.js"></script>
</head>
<body>
<div class="main">
	<!-- banner -->
	<div class="banner">
		<div class="swiper-container swiper1">
			<div class="swiper-wrapper" id="div_banner">
				<!--<div class="swiper-slide">banner1</div>-->
				<!--<div class="swiper-slide">banner2</div>-->
				<!--<div class="swiper-slide">banner3</div>-->
				<!--<div class="swiper-slide">banner4</div>-->
			</div>
			<div class="pagination"></div>
		</div>
		<!-- 登录图标 -->
		<div class="icon login" onclick="ClickLogin()"></div>
	</div>
	<div class="bg-box">
		<!-- search -->
		<div class="search">
			<!-- <input type="text" name="" placeholder="搜索你要找的影评或影片名称" class="s-input" /> -->
			<a class="s-input" href="/mobilesearch">搜索你要找的影评或影片名称</a>
			<div class="icon s-btn"></div>
		</div>
		<!-- classify -->
		<div class="classify">
			<div class="swiper-container swiper2">
				<div class="swiper-wrapper">
					<div class="swiper-slide classify-slide">
							<span class="classify-list" onclick="ClickType('')">
								<div class="list-icon icon1"></div>
								<div class="list-t">全部</div>
							</span>
						<span class="classify-list"  onclick="ClickType('0')">
								<div class="list-icon icon2"></div>
								<div class="list-t">喜剧</div>
							</span>
						<span class="classify-list" onclick="ClickType('1')">
								<div class="list-icon icon3"></div>
								<div class="list-t">爱情</div>
							</span>
						<span class="classify-list" onclick="ClickType('2')">
								<div class="list-icon icon4"></div>
								<div class="list-t">动作</div>
							</span>
						<span class="classify-list" onclick="ClickType('3')">
								<div class="list-icon icon5"></div>
								<div class="list-t">恐怖</div>
							</span>
						<span class="classify-list"  onclick="ClickType('4')">
								<div class="list-icon icon6"></div>
								<div class="list-t">科幻</div>
							</span>
						<span class="classify-list"  onclick="ClickType('5')">
								<div class="list-icon icon7"></div>
								<div class="list-t">剧情</div>
							</span>
						<span class="classify-list"  onclick="ClickType('6')">
								<div class="list-icon icon8"></div>
								<div class="list-t">犯罪</div>
							</span>
						<span class="classify-list"  onclick="ClickType('7')">
								<div class="list-icon icon9"></div>
								<div class="list-t">奇幻</div>
							</span>
						<span class="classify-list"  onclick="ClickType('8')">
								<div class="list-icon icon10"></div>
								<div class="list-t">战争</div>
							</span>
						<span class="classify-list"  onclick="ClickType('9')">
								<div class="list-icon icon11"></div>
								<div class="list-t">悬疑</div>
							</span>
						<span class="classify-list"  onclick="ClickType('10')">
								<div class="list-icon icon12"></div>
								<div class="list-t">动画</div>
							</span>
						<span class="classify-list" onclick="ClickType('11')">
								<div class="list-icon icon13"></div>
								<div class="list-t">伦理</div>
							</span>
						<span class="classify-list" onclick="ClickType('12')">
								<div class="list-icon icon14"></div>
								<div class="list-t">记录</div>
							</span>
						<span class="classify-list" onclick="ClickType('13')">
								<div class="list-icon icon15"></div>
								<div class="list-t">传记</div>
							</span>
						<span class="classify-list" onclick="ClickType('13')">
								<div class="list-icon icon16"></div>
								<div class="list-t">歌舞</div>
							</span>
						<span class="classify-list" onclick="ClickType('14')">
								<div class="list-icon icon17"></div>
								<div class="list-t">古装</div>
							</span>
						<span class="classify-list" onclick="ClickType('15')">
								<div class="list-icon icon18"></div>
								<div class="list-t">历史</div>
							</span>
						<span class="classify-list" onclick="ClickType('16')">
								<div class="list-icon icon19"></div>
								<div class="list-t">惊悚</div>
							</span>
						<span class="classify-list" onclick="ClickType('17')">
								<div class="list-icon icon20"></div>
								<div class="list-t">文艺</div>
							</span>
					</div>
				</div>
			</div>
		</div>
	</div>
	<!-- 影片展示 -->
	<div class="moves">
		<div class="m-title">
			<i class="m-type">热播</i>
		</div>
		<div class="m-box" id="div_item_content">
			<div class="list-box">
					<span class="m-list m-flist">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
				<span class="m-list">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
				<span class="m-list m-elist">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
			</div>
			<div class="list-box">
					<span class="m-list m-flist">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
				<span class="m-list">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
				<span class="m-list m-elist">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
			</div>
		</div>
	</div>
	<div class="moves" id="div_tuijian">
		<div class="m-title">
			<i class="m-type">喜剧</i>
			<i class="m-more">查看更多></i>
		</div>
		<div class="m-box" >
			<div class="list-box">
					<span class="m-list m-flist">
						<div class="m-img"><img src="" /></div>
						<div class="m-name">180°以南</div>
					</span>
				<span class="m-list">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
				<span class="m-list m-elist">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
			</div>
			<div class="list-box">
					<span class="m-list m-flist">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
				<span class="m-list">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
				<span class="m-list m-elist">
						<div class="m-img"></div>
						<div class="m-name">180°以南</div>
					</span>
			</div>
		</div>
	</div>
	<!-- footer -->
	<div class="footer"></div>
	<!-- come back top -->
	<div class="icon c-top" id="goToTop">

	</div>
</div>
<script type="text/javascript" src="/js/mobile/lib/idangerous.swiper.min.js"></script>
<script type='text/javascript' src='/js/mobile/mobilecom.js' charset='utf-8'></script>
<script type="text/javascript" src="/js/jquery/jquery.cookie.js"></script>
<script type="text/javascript" src="/js/mobile/tools.js"></script>

<script type="text/javascript">
    $(function(){
        (function (doc, win) {

            var docEl = doc.documentElement,
                resizeEvt = 'orientationchange' in window ? 'orientationchange' : 'resize';
            var clientWidth = '',newWidth = '',swiper2;
            recalc = function () {

                newWidth = $(window).width();

                if(newWidth === clientWidth) return false;

                clientWidth = newWidth;

                docEl.style.fontSize = 100 * (clientWidth / 750) + 'px';

                setTimeout(function(){

                    var _num = $(".classify-list").length,_width = $(".classify-list").width();

                    console.log(_num*_width);

                    $(".classify-slide").width(_width*_num + 10 + "px");

                    new Swiper(".swiper2",{

                        scrollContainer: true
                    })

                }, 65)

            };

            if (!doc.addEventListener) return;

            win.addEventListener(resizeEvt, recalc, false);

            recalc();

        })(document, window);



        var d = [
            {"src": 1,"name": "xiaoming"},
            {"src": 1,"name": "xiaoming"},
            {"src": 1,"name": "xiaoming"},
            {"src": 1,"name": "xiaoming"},
            {"src": 1,"name": "xiaoming"},
            {"src": 1,"name": "xiaoming"},
            {"src": 1,"name": "xiaoming"},
            {"src": 1,"name": "xiaoming"}]

        //console.log($.worksListTemplate(d));
        LoadBanner();

        LoadHotVidoe();

        LoadTuijianVidoe();
    });
    function ClickType(typeid){
        window.location.href='/movelist?typeid='+typeid;
    }
    function LoadBanner() {
        $.ajax({
            type: 'get',
            url: '/api/film/getByPlayctfilmlist?limit=4',
            dataType: 'json',
            success: function(data){
                if(mortise_layout.ValidataResult(data)){
                    //{"code":"OperateOk","errorMsg":"","result":{"list":[{"fId":"594cabc05bc42d07a0aa541a","fName":"一个钓鱼的故事","fFilmtype":"1000010100000000000","fYear":2016,"fCountry":12,"fKeyword":"一个钓鱼的故事","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a87fe37ca1d108069af15.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adca774c36b070e69ec8e.jpg","fDirector":"Matt Birman","fPerformer":"Eddie McClintock, Jayne Heitmeyer, Jordyn Negri ","fShowtime":"2016-12-12","fScore":0.0,"fPricetagid":"0","fPricetagname":"免费电影","fIntime":"2017-06-23 14:20:23","fShow":1,"fLookct":0,"fMakelookct":11,"fGoodct":0,"fMakegoodct":12,"fCollect":2,"fMakecollect":13,"fPlayct":132,"fMakepalyct":15,"fSharect":0,"fMakesharect":null,"fBuyct":0,"fCommentct":22,"fSourceurl":null,"fCountryname":"加拿大","fFilmtypename":"喜剧/剧情/奇幻","fImpression":"印象"},{"fId":"5930e4cd1c886e2dc0d45342","fName":"末世迷踪：下一代","fFilmtype":"0000000100000000000","fYear":2016,"fCountry":4,"fKeyword":"末世迷踪：下一代","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a88f137ca1d108069af17.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adcc774c36b070e69ec90.jpg","fDirector":"Larry A. McLean","fPerformer":" Amber Frank, Mason Dye, Dylan Sprayberry","fShowtime":"2017-06-02","fScore":0.0,"fPricetagid":"0","fPricetagname":"免费电影","fIntime":"2017-06-02 12:08:34","fShow":1,"fLookct":1,"fMakelookct":15,"fGoodct":2,"fMakegoodct":25,"fCollect":2,"fMakecollect":0,"fPlayct":17,"fMakepalyct":5,"fSharect":1,"fMakesharect":null,"fBuyct":0,"fCommentct":4,"fSourceurl":null,"fCountryname":"美国","fFilmtypename":"奇幻","fImpression":null},{"fId":"594c95065bc42d07a03f1fac","fName":"大婴儿","fFilmtype":"1100010000000000000","fYear":2015,"fCountry":4,"fKeyword":"大婴儿","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a887337ca1d108069af16.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adcb874c36b070e69ec8f.jpg","fDirector":"Stephen Langford","fPerformer":"Maureen McCormick, Andrew Lawrence, Ken Davitian","fShowtime":"2015-12-12","fScore":0.0,"fPricetagid":"1","fPricetagname":"2元电影","fIntime":"2017-06-23 12:43:35","fShow":1,"fLookct":0,"fMakelookct":11,"fGoodct":0,"fMakegoodct":12,"fCollect":1,"fMakecollect":13,"fPlayct":11,"fMakepalyct":15,"fSharect":0,"fMakesharect":null,"fBuyct":0,"fCommentct":4,"fSourceurl":null,"fCountryname":"美国","fFilmtypename":"喜剧/爱情/剧情","fImpression":"印象"},{"fId":"594cacc75bc42d07a0aa541b","fName":"正义","fFilmtype":"1100000000000000000","fYear":2016,"fCountry":4,"fKeyword":"正义","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a87a137ca1d108069af14.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adc9d74c36b070e69ec8d.jpg","fDirector":"Richard Gabai","fPerformer":" Stephen Lang, Jackson Rathbone, Jamie-Lynn Sigler ","fShowtime":"2016-12-12","fScore":0.0,"fPricetagid":"0","fPricetagname":"免费电影","fIntime":"2017-06-23 14:24:45","fShow":1,"fLookct":0,"fMakelookct":11,"fGoodct":0,"fMakegoodct":12,"fCollect":0,"fMakecollect":13,"fPlayct":4,"fMakepalyct":15,"fSharect":0,"fMakesharect":null,"fBuyct":0,"fCommentct":0,"fSourceurl":null,"fCountryname":"美国","fFilmtypename":"喜剧/爱情","fImpression":"印象"}]},"allcount":0}
                    var videoList=data.result.list;
                    if(videoList&& videoList.length>0){
                        var _html='';

                        $.each(videoList,function (index,item) {

//                                _html += '<li class="slider-item openParam" data-param="' + url + '"' +
//                                    'data-baidu-action="banner" data-baidu-label="' + (parseInt(index) + 1) + '">' +
//                                    '<div class="img-wrap" onclick="GoToVideoInfo(\''+item.fId+'\')"><img class="banner-image" src="' +
//                                    item.fPhotow+ '"/></div></li>';
                            _html+='<div class="swiper-slide" onclick="GoToVideoInfo(\''+item.fId+'\')"><img class="banner-image" src="' +
                                item.fPhotow+ '"/></div>';

                        });

                        $('#div_banner').html(_html);
                        new Swiper(".swiper1",{
                            loop: true,
                            speed: 1500,
                            pagination: ".pagination",
                            autoplay: 2000
                        });
//                            $("#div_banner").slider({
//                                "autoScroll": true,
//                                "infinite": true
//                            });
                    }

                }
            }
        });
    }

    //加载热播
    function LoadHotVidoe() {
        $.ajax({
            type: 'get',
            url: '/api/film/getnewsvideolist?filmcount=6&shortvideoct=0',
            dataType: 'json',
            success: function(data){
                if(mortise_layout.ValidataResult(data)){
                    //{"code":"OperateOk","errorMsg":"","result":{"list":[{"fId":"594cabc05bc42d07a0aa541a","fName":"一个钓鱼的故事","fFilmtype":"1000010100000000000","fYear":2016,"fCountry":12,"fKeyword":"一个钓鱼的故事","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a87fe37ca1d108069af15.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adca774c36b070e69ec8e.jpg","fDirector":"Matt Birman","fPerformer":"Eddie McClintock, Jayne Heitmeyer, Jordyn Negri ","fShowtime":"2016-12-12","fScore":0.0,"fPricetagid":"0","fPricetagname":"免费电影","fIntime":"2017-06-23 14:20:23","fShow":1,"fLookct":0,"fMakelookct":11,"fGoodct":0,"fMakegoodct":12,"fCollect":2,"fMakecollect":13,"fPlayct":132,"fMakepalyct":15,"fSharect":0,"fMakesharect":null,"fBuyct":0,"fCommentct":22,"fSourceurl":null,"fCountryname":"加拿大","fFilmtypename":"喜剧/剧情/奇幻","fImpression":"印象"},{"fId":"5930e4cd1c886e2dc0d45342","fName":"末世迷踪：下一代","fFilmtype":"0000000100000000000","fYear":2016,"fCountry":4,"fKeyword":"末世迷踪：下一代","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a88f137ca1d108069af17.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adcc774c36b070e69ec90.jpg","fDirector":"Larry A. McLean","fPerformer":" Amber Frank, Mason Dye, Dylan Sprayberry","fShowtime":"2017-06-02","fScore":0.0,"fPricetagid":"0","fPricetagname":"免费电影","fIntime":"2017-06-02 12:08:34","fShow":1,"fLookct":1,"fMakelookct":15,"fGoodct":2,"fMakegoodct":25,"fCollect":2,"fMakecollect":0,"fPlayct":17,"fMakepalyct":5,"fSharect":1,"fMakesharect":null,"fBuyct":0,"fCommentct":4,"fSourceurl":null,"fCountryname":"美国","fFilmtypename":"奇幻","fImpression":null},{"fId":"594c95065bc42d07a03f1fac","fName":"大婴儿","fFilmtype":"1100010000000000000","fYear":2015,"fCountry":4,"fKeyword":"大婴儿","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a887337ca1d108069af16.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adcb874c36b070e69ec8f.jpg","fDirector":"Stephen Langford","fPerformer":"Maureen McCormick, Andrew Lawrence, Ken Davitian","fShowtime":"2015-12-12","fScore":0.0,"fPricetagid":"1","fPricetagname":"2元电影","fIntime":"2017-06-23 12:43:35","fShow":1,"fLookct":0,"fMakelookct":11,"fGoodct":0,"fMakegoodct":12,"fCollect":1,"fMakecollect":13,"fPlayct":11,"fMakepalyct":15,"fSharect":0,"fMakesharect":null,"fBuyct":0,"fCommentct":4,"fSourceurl":null,"fCountryname":"美国","fFilmtypename":"喜剧/爱情/剧情","fImpression":"印象"},{"fId":"594cacc75bc42d07a0aa541b","fName":"正义","fFilmtype":"1100000000000000000","fYear":2016,"fCountry":4,"fKeyword":"正义","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a87a137ca1d108069af14.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adc9d74c36b070e69ec8d.jpg","fDirector":"Richard Gabai","fPerformer":" Stephen Lang, Jackson Rathbone, Jamie-Lynn Sigler ","fShowtime":"2016-12-12","fScore":0.0,"fPricetagid":"0","fPricetagname":"免费电影","fIntime":"2017-06-23 14:24:45","fShow":1,"fLookct":0,"fMakelookct":11,"fGoodct":0,"fMakegoodct":12,"fCollect":0,"fMakecollect":13,"fPlayct":4,"fMakepalyct":15,"fSharect":0,"fMakesharect":null,"fBuyct":0,"fCommentct":0,"fSourceurl":null,"fCountryname":"美国","fFilmtypename":"喜剧/爱情","fImpression":"印象"}]},"allcount":0}
                    var videoList=data.result.filmlist;
                    if(videoList&& videoList.length>0){
                        var _html='';
                        $.each(videoList,function (index,item) {
                            if (index%3==0){
                                _html+='<div class="list-box">';
                            }
//                                _html+='<div class="movieImg1"   onclick="GoToVideoInfo(\''+item.fId+'\')">'
//                                _html+=  '<img src="'+item.fPhotow+'"'
//                                _html+=   'alt="" style="width: 100%" />'
//                                _html+=  '<span class="movieName">'+ item.fName
//                                _html+=  '</span>'
//                                _html+=   '<span class="movieExplain">'+item.fKeyword+'</span>'
//                                _html+=   '</div>';
                            if(index%3==0){
                                _html+='<span class="m-list m-flist" onclick="GoToVideoInfo(\''+item.fId+'\')">';
                            }
                            else if (index%3==1){
                                _html+='<span class="m-list m-mlist" onclick="GoToVideoInfo(\''+item.fId+'\')">';
                            }
                            else if (index%3==2){
                                _html+='<span class="m-list m-elist" onclick="GoToVideoInfo(\''+item.fId+'\')">';
                            }

                            _html+=' <div class="m-img"><img src="'+item.fPhoto+'" /></div>';
                            _html+='  <div class="m-name">'+item.fName+'</div>';
                            _html+='</span>';
                            if (index%3==2){
                                _html+='</div>'
                            }
                        });
                        $('#div_item_content').html(_html);
                    }

                }
            }
        });
    }
    //加载下边推荐

    function LoadTuijianVidoe() {
        //
        $('#div_tuijian').html('');
        $.ajax({
            type: 'get',
            url: '/api/film/getfilmtypslist?filmtypestr=0,2,4&count=3',
            dataType: 'json',
            success: function(data){
                if(mortise_layout.ValidataResult(data)){
                    //{"code":"OperateOk","errorMsg":"","result":{"list":[{"fId":"594cabc05bc42d07a0aa541a","fName":"一个钓鱼的故事","fFilmtype":"1000010100000000000","fYear":2016,"fCountry":12,"fKeyword":"一个钓鱼的故事","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a87fe37ca1d108069af15.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adca774c36b070e69ec8e.jpg","fDirector":"Matt Birman","fPerformer":"Eddie McClintock, Jayne Heitmeyer, Jordyn Negri ","fShowtime":"2016-12-12","fScore":0.0,"fPricetagid":"0","fPricetagname":"免费电影","fIntime":"2017-06-23 14:20:23","fShow":1,"fLookct":0,"fMakelookct":11,"fGoodct":0,"fMakegoodct":12,"fCollect":2,"fMakecollect":13,"fPlayct":132,"fMakepalyct":15,"fSharect":0,"fMakesharect":null,"fBuyct":0,"fCommentct":22,"fSourceurl":null,"fCountryname":"加拿大","fFilmtypename":"喜剧/剧情/奇幻","fImpression":"印象"},{"fId":"5930e4cd1c886e2dc0d45342","fName":"末世迷踪：下一代","fFilmtype":"0000000100000000000","fYear":2016,"fCountry":4,"fKeyword":"末世迷踪：下一代","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a88f137ca1d108069af17.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adcc774c36b070e69ec90.jpg","fDirector":"Larry A. McLean","fPerformer":" Amber Frank, Mason Dye, Dylan Sprayberry","fShowtime":"2017-06-02","fScore":0.0,"fPricetagid":"0","fPricetagname":"免费电影","fIntime":"2017-06-02 12:08:34","fShow":1,"fLookct":1,"fMakelookct":15,"fGoodct":2,"fMakegoodct":25,"fCollect":2,"fMakecollect":0,"fPlayct":17,"fMakepalyct":5,"fSharect":1,"fMakesharect":null,"fBuyct":0,"fCommentct":4,"fSourceurl":null,"fCountryname":"美国","fFilmtypename":"奇幻","fImpression":null},{"fId":"594c95065bc42d07a03f1fac","fName":"大婴儿","fFilmtype":"1100010000000000000","fYear":2015,"fCountry":4,"fKeyword":"大婴儿","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a887337ca1d108069af16.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adcb874c36b070e69ec8f.jpg","fDirector":"Stephen Langford","fPerformer":"Maureen McCormick, Andrew Lawrence, Ken Davitian","fShowtime":"2015-12-12","fScore":0.0,"fPricetagid":"1","fPricetagname":"2元电影","fIntime":"2017-06-23 12:43:35","fShow":1,"fLookct":0,"fMakelookct":11,"fGoodct":0,"fMakegoodct":12,"fCollect":1,"fMakecollect":13,"fPlayct":11,"fMakepalyct":15,"fSharect":0,"fMakesharect":null,"fBuyct":0,"fCommentct":4,"fSourceurl":null,"fCountryname":"美国","fFilmtypename":"喜剧/爱情/剧情","fImpression":"印象"},{"fId":"594cacc75bc42d07a0aa541b","fName":"正义","fFilmtype":"1100000000000000000","fYear":2016,"fCountry":4,"fKeyword":"正义","fPhoto":"http://119.10.70.142:9080/Images/upload/videoPhoto/595a87a137ca1d108069af14.png","fPhotow":"http://101.201.122.79:8083/Images/upload/videoPhoto/596adc9d74c36b070e69ec8d.jpg","fDirector":"Richard Gabai","fPerformer":" Stephen Lang, Jackson Rathbone, Jamie-Lynn Sigler ","fShowtime":"2016-12-12","fScore":0.0,"fPricetagid":"0","fPricetagname":"免费电影","fIntime":"2017-06-23 14:24:45","fShow":1,"fLookct":0,"fMakelookct":11,"fGoodct":0,"fMakegoodct":12,"fCollect":0,"fMakecollect":13,"fPlayct":4,"fMakepalyct":15,"fSharect":0,"fMakesharect":null,"fBuyct":0,"fCommentct":0,"fSourceurl":null,"fCountryname":"美国","fFilmtypename":"喜剧/爱情","fImpression":"印象"}]},"allcount":0}
                    var videoList=data.result;

                    if(videoList){
                        var _html='';
                        $.each(videoList,function (key,item) {
                            _html+='	<div class="m-title">';
                            _html+='<i class="m-type">'+GetVideoTypeNameList(key)+'</i>';
                            _html+='<i class="m-more" onclick="ClickType(\''+key+'\')">查看更多></i>';
                            _html+='</div>';

                            //内容循环
                            if(item&& item.length>0){
                                var _rowHtml='';
                                $.each(item,function (index,item1){
                                    if(index%3==0){
                                        _html+='<span class="m-list m-flist" onclick="GoToVideoInfo(\''+item1.fId+'\')">';
                                    }
                                    else if (index%3==1){
                                        _html+='<span class="m-list  m-mlist" onclick="GoToVideoInfo(\''+item1.fId+'\')">';
                                    }
                                    else if (index%3==2){
                                        _html+='<span class="m-list m-elist" onclick="GoToVideoInfo(\''+item1.fId+'\')">';
                                    }

                                    _html+=' <div class="m-img"><img src="'+item1.fPhoto+'" /></div>';
                                    _html+='  <div class="m-name">'+item1.fName+'</div>';
                                    _html+='</span>';
                                    if (index%3==2){
                                        _html+='</div>'
                                    }
                                });
                                _html+='<div class="m-box" ><div class="list-box">'+_rowHtml+'</div></div>';
                            }

                        });
                        $('#div_tuijian').html(_html);
                    }

                }
            }
        });
    }
    function ClickLogin() {

        var user_cookie=$.cookie('mortise_loginToken');
        if (user_cookie){

            window.location.href='/usercenter';
        }
        else{
            ShowLogin();
        }

    }

    //登录
    function UserLogin(func){
        var phone=$('#input_phone').val();
        var pwd=$('#input_pwd').val();
        var phonetest = /^1[34578]\d{9}$/;
        var pwdtest = /^[a-zA-Z0-9]{6,20}$/;
        if(!phonetest.test(phone)){
            alert('请输入正确的手机号码！');
            return false;
		}
        if(!pwdtest.test(pwd)){
            alert('请输入6到20位的字母或数字的密码！');
            return false;
        }

        if (!phone){
            alert('请输入手机号码！');
            return false;
        }
        if (!pwd){
            alert('请输入密码！');
            return false;
        }
        $.ajax({
            type: 'POST',
            url: 'api/user/loginuser',
            data: { phone: phone,password:pwd,loginapp:6},
            dataType: 'json',
            success: function(data){
                if (data.code=='LoginSucess') {
                    alert('登录成功！');
                    $(".login-reg").remove();
                    $(".page-m").hide();
                    if (typeof (func)=='function'){
                        func();
                    }
                }
                else if (data.code=='NoLogin'||data.code=='LoginFail'){
                    alert("帐号和密码有误，登录失败")
                }
                else if (data.code=='LoginPassError'){
                    alert('帐号和密码有误，登录失败！');
                }

            }
        });
    }


    $(document).ready(function(){
        $("#goToTop").hide()//隐藏go to top按钮
        $(function(){
            $(window).scroll(function(){
                if($(this).scrollTop()>1){//当window的scrolltop距离大于1时，go to top按钮淡出，反之淡入
                    $("#goToTop").fadeIn();
                } else {
                    $("#goToTop").fadeOut();
                }
            });
        });


        // 给go to top按钮一个点击事件
        $("#goToTop").click(function(){
            $("html,body").animate({scrollTop:0},800);//点击go to top按钮时，以800的速度回到顶部，这里的800可以根据你的需求修改
            return false;
        });
    });

</script>
</body>
</html>